package com.example.hangzhou.welbeing.mytestdemoapp.designPatterns.CreatorModel.MyTest;

import com.example.hangzhou.welbeing.mytestdemoapp.designPatterns.CreatorModel.MyInter.MyItem;

import java.util.ArrayList;
import java.util.List;

/**
 * 杭州惟君医疗科技有限公司11
 * Created by 20433 on 2018/5/17
 *
 * @desc 东风山河绿，春已不折柳，繁花看不尽，处处惹人留
 * @desc 佛祖镇楼，bug辟容易
 */

public class MyMeal {
    private List<MyItem> mlist = new ArrayList();

    public void  addItem(MyItem myItem){
        mlist.add(myItem);
    }

    public int getfloatItenm(){
        int intenm = 0;
        for (MyItem myItem : mlist) {
            intenm += myItem.floatItenm();
        }
        return  intenm;
    }

    public void  show(){
        for (MyItem myItem : mlist) {
            myItem.drwa();
            myItem.packing().find();
            myItem.floatItenm();
        }
    }
}
